{include file="public/_meta" /}
<link href="__PUBLIC_ADMIN__css/plugins/iCheck/custom.css" rel="stylesheet">
</head>

<body class="gray-bg">
    <div class="wrapper wrapper-content animated fadeInRight">
    <div class="ibox-title">
                        <h5>编辑推广游戏</h5>
                        <div class="ibox-tools">
							<a href="{:url('admin/idiom/extension_list')}"
								class="btn btn-primary btn-xs">返回列表</a>
						</div>
                    </div>
        <div class="row">
            <div class="col-sm-12">
                <div class="ibox float-e-margins">
                    <div class="ibox-content">
                        <form action="{:url('admin/idiom/extension_edit_post')}" method="post" class="form-horizontal" enctype="multipart/form-data">
                        	<input type="hidden" name="id" value="{$res.id}" />
                        	<div class="hr-line-dashed"></div>
							<div class="form-group">
								<label class="col-sm-2 control-label">推广类型：</label>
								<div class="col-sm-4">
									<select class="form-control" name="type">
										<option value="1" class="dis" {if condition="$res.type eq 1"} selected="selected" {/if}>首页</option>
										<option value="0" class="str" {if condition="$res.type eq 0"} selected="selected" {/if}>更多游戏</option>
									</select>
								</div>
							</div>
							<div class="form-group">
								<label class="col-sm-2 control-label">游戏LOGO：</label>
								<div class="col-sm-10">
									<div class="up">
										<input placeholder="" name="file" class="one" type="file">
										<div id="preview1">
											<img src="__IMG_UP__{$res.img}" alt="">
										</div>
									</div>
								</div>
							</div>
							<div class="hr-line-dashed"></div>
							<div class="form-group">
								<label class="col-sm-2 control-label">游戏名称：</label>
								<div class="col-sm-10">
									<input type="text" class="form-control" value="{$res.title}" name="title"> 
								</div>
							</div>
							<div class="hr-line-dashed"></div>
							<div class="form-group">
								<label class="col-sm-2 control-label">游戏简介：</label>
								<div class="col-sm-10">
									<input type="text" class="form-control" value="{$res.content}" name="content">
								</div>
							</div>
							<div class="hr-line-dashed"></div>
							<div class="form-group">
								<label class="col-sm-2 control-label">跳转链接：</label>
								<div class="col-sm-10">
									<input type="text" class="form-control" value="{$res.url}" name="url">
								</div>
							</div>
                            <div class="form-group">
                                <div class="col-sm-4 col-sm-offset-2">
                                    <button class="btn btn-primary" type="submit">保存内容</button>
                                </div>
                            </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </div>

    {include file="public/_footer" /}
	
    <!-- 自定义js -->
    <script src="__PUBLIC_ADMIN__js/content.js?v=1.0.0"></script>
    
    <!-- iCheck -->
    <script src="__PUBLIC_ADMIN__js/plugins/iCheck/icheck.min.js"></script>
    
    <script>
        $(document).ready(function() {
        	$('.i-checks').iCheck({
                checkboxClass: 'icheckbox_square-green',
                radioClass: 'iradio_square-green',
            });
			
            $('.refresh').click(function(){
            	//window.location.reload();	// 刷新页面
            })
		});
	</script>
</body>
</html>
